package gov.child.entities.vo;

import gov.child.entities.po.EDepartment;
import gov.child.entities.vo.annotation.Alias;

/**
 * @author fzh
 * @since 2017/9/14
 */
public class Department  {
    @Alias("id")
    private Integer departmentId;
    private String deptCode;
    private String deptName;
    private String deptAddr;
    private String deptTel;
    private Integer deptParent;

    public static final Department EMPTY_DEPARTMENT = new Department();

    public static Department parseFrom(EDepartment department) {
        return BeanTransformer.transform(Department.class, department);
    }

    public static EDepartment parseTo(Department department) {
        return BeanTransformer.transform(EDepartment.class, department);
    }

    public Integer getDepartmentId() {
        return departmentId;
    }

    public void setDepartmentId(Integer departmentId) {
        this.departmentId = departmentId;
    }

    public String getDeptCode() {
        return deptCode;
    }

    public void setDeptCode(String deptCode) {
        this.deptCode = deptCode;
    }

    public String getDeptName() {
        return deptName;
    }

    public void setDeptName(String deptName) {
        this.deptName = deptName;
    }

    public String getDeptAddr() {
        return deptAddr;
    }

    public void setDeptAddr(String deptAddr) {
        this.deptAddr = deptAddr;
    }

    public String getDeptTel() {
        return deptTel;
    }

    public void setDeptTel(String deptTel) {
        this.deptTel = deptTel;
    }

    public Integer getDeptParent() {
        return deptParent;
    }

    public void setDeptParent(Integer deptParent) {
        this.deptParent = deptParent;
    }

    @Override
    public String toString() {
        return "Department{" +
                "departmentId=" + departmentId +
                ", deptCode='" + deptCode + '\'' +
                ", deptName='" + deptName + '\'' +
                ", deptAddr='" + deptAddr + '\'' +
                ", deptTel='" + deptTel + '\'' +
                ", deptParent=" + deptParent +
                '}';
    }
}
